<?php
/**
 * 简单的工厂设计模式 使用composer psr4 自动加载机制
 */

include __DIR__ . "/../../vendor/autoload.php";
use src\controller\Factory;

$factory =  new Factory();
$pay=$factory::pay("WeChatPay");
$pay->pay();
$pay1=$factory::pay("AliPay");
var_dump($pay1->pay());